<style>
    .ui-popup-modal .ui-dialog-body {
        /*padding: 0;*/
    }

    .table-responsive .no-data {
        height: 170px;
    }

    .table-responsive .no-data span {
        margin-top: 40px;
    }

    .w100p {
        width: 100%;
    }

    #xqqr label {
        width: 60px;
        display: inline-block;
    }

    #xqqr .checkbox label, .checkbox span {
        width: auto;
    }

    .remind {
        max-height: 490px;
    }

</style>
<div i="content" class="remind ui-dialog-content">
    <div class="step-info">
        <div class="mb10">
            <table class="steps" cellspacing="0" cellpadding="0">
                <tbody>
                <tr>
                    <td class="first-step" ng-class="{active: step==1}">
                        <div>1.选择要汇报的项目<span class="after"></span></div>
                    </td>
                    <td ng-class="{active: step==2}">
                        <div><span class="before"></span>2.汇报续签进展</div>
                    </td>
                </tr>
                </tbody>
            </table>
        </div>
    </div>
    <div style="width: 760px;" ng-show="step == 1">
        <div class="w100p">

            <table>
                <!--<tr ng-hide="isProject">-->
                    <!--<td width="100" align="right">合同号：</td>-->
                    <!--<td colspan="6">-->
                        <!--<div style="width: 665px;" ui-combobox data="needRenewContracts" ng-model="contractId"-->
                             <!--text-field="ContractCode"-->
                             <!--value-field="ContractId"></div>-->
                    <!--</td>-->
                <!--</tr>-->
                <tr>
                    <td class="pt16" align="right" ng-hide="isProject">项目所在地：</td>
                    <td class="pt16" ng-hide="isProject">
                        <div style="width: 85px;margin-right: 10px;" ui-combobox data="cites" ng-model="city"
                             text-field="text"
                             value-field="value"></div>
                    </td>
                    <td class="pt16" align="right">租期状态：</td>
                    <td class="pt16">
                        <div style="width: 90px;margin-right: 10px;" ui-combobox data="htStatus" ng-model="status"
                             text-field="name"
                             value-field="name"></div>
                    </td>
                    <td class="pt16" align="right">汇报状态：</td>
                    <td class="pt16">
                        <div style="width: 100px;margin-right: 46px;" ui-combobox data="xqStatus" ng-model="xq"
                             text-field="text"
                             value-field="value"></div>
                    </td>
                    <td class="pt16" ng-hide="isProject">
                        <div class="fr">
                            <input type="text" class="input-text fl mr5"
                                   style="width: 120px;"
                                   placeholder="项目名称" ng-model="projectName"
                                   ng-enter="localSearch()">
                            <a class="btn" ng-click="localSearch()">搜索</a>
                        </div>
                    </td>
                </tr>
            </table>

            <div id="xqqr" class="table-responsive mt20" style="max-height: 246px;overflow-y: scroll;">
                <table class="table">
                    <thead>
                    <tr>
                        <th width="50" class="text-center">
                            <label class="checkbox">
                                <input type="checkbox" id="cb2" name="cb1" value="1" ng-model="allChecked"
                                       ng-click="allCheckedClick()">
                                <span>序号</span>
                            </label>
                        </th>
                        <th width="80">项目所在地</th>
                        <th width="80">项目名称</th>
                        <th width="80">产品名称</th>
                        <th width="120">产品租期</th>
                        <th width="80">状态</th>
                        <th width="120">合同号</th>
                        <th width="120">汇报结果</th>
                    </tr>
                    </thead>
                    <tbody>
                    <tr ng-repeat="item in items">
                        <td>
                            <label class="checkbox">
                                <input type="checkbox" name="cb1" value="1" ng-disabled="item.IsXq != null"
                                       ng-model="item.checked">
                                <span>{{ $index + 1 }}</span>
                            </label>
                        </td>
                        <td>
                            {{ item.City }}
                        </td>
                        <td>
                            {{ item.ProjectName }}
                        </td>
                        <td>
                            {{ item.AppName }}
                        </td>
                        <td>
                            {{ item.BeginOn | limitTo:10 + '至' + item.EndOn | limitTo:10}}
                        </td>
                        <td>
                            {{ item.Status }}
                        </td>
                        <td>
                            {{ item.ContractCode }}
                        </td>
                        <td>
                            {{ item.IsXq | xqResult:item.XqResult }}
                        </td>
                    </tr>
                    </tbody>
                </table>
                <div class="no-data" ng-hide="items && items.length"><span>暂无数据</span></div>
            </div>
        </div>
    </div>
    <form class="ui-dialog-content f12" name="set_remind_form"
          style="width: 760px;max-height: 340px;overflow-y: scroll;" ng-show="step == 2">
        <table width="100%">
            <tbody>
            <tr>
                <td class="form-cell w100 pt16" align="right" valign="top">
                    <span class="c-red">* </span>续签进展：
                </td>
                <td class="form-cell pt16" colspan="3">
                    <input type="radio" name="data.isXq" ui-radio="部分续签" value="1" ng-model="data.isXq">
                    <span class="ml30">
                        <input type="radio" name="data.isXq" ui-radio="全部续签" value="2" ng-model="data.isXq">
                    </span>
                    <span class="ml30">
                        <input type="radio" name="data.isXq" ui-radio="不续签" value="0" ng-model="data.isXq">
                    </span>
                </td>
                <td>
                    <div class="question-tip fr">
                        <i class="iconfont-common icon-question fl pt12"></i>
                        <div class="tip-wrap tip-wrap-pic">
                            <span class="fl">一旦做了续签汇报，将不会再收到该合同的续签提醒。确认续签时，需勾选续签明细，项目名称到具体的应用。</span>
                        </div>
                    </div>
                </td>
            </tr>
            <tr ng-if="data.isXq == '1' || data.isXq == '2'">
                <td class="form-cell w100 pt16" align="right" valign="top">
                    <span class="c-red">* </span>续签节点：
                </td>
                <td class="form-cell pt16" colspan="3">
                    <input type="radio" name="data.renewStatus" ui-radio="商务谈判中" value="1" ng-model="data.renewStatus">
                    <span class="ml30">
                        <input type="radio" name="data.renewStatus" ui-radio="合同流程中" value="2"
                               ng-model="data.renewStatus">
                    </span>
                    <span class="ml30">
                        <input type="radio" name="data.renewStatus" ui-radio="款项申请中" value="3"
                               ng-model="data.renewStatus">
                    </span>
                    <span class="ml30">
                        <input type="radio" name="data.renewStatus" ui-radio="续签完成" value="4"
                               ng-model="data.renewStatus">
                    </span>
                </td>
            </tr>
            <tr ng-if="data.isXq == '1' || data.isXq == '0'">
                <td class="form-cell w100 pt16" align="right" valign="top">
                    <span class="c-red">* </span>不续签原因：
                </td>
                <td class="form-cell pt16" colspan="3">
                    <input type="radio" name="data.noRenewReason" ui-radio="项目售罄" value="1"
                           ng-model="data.noRenewReason">
                    <span class="ml30">
                        <input type="radio" name="data.noRenewReason" ui-radio="应用不好" value="2"
                               ng-model="data.noRenewReason">
                    </span>
                    <span class="ml30">
                        <input type="radio" name="data.noRenewReason" ui-radio="其他" value="3"
                               ng-model="data.noRenewReason">
                    </span>
                </td>
            </tr>
            <tr>
                <td class="form-cell w100" align="right" valign="top">说明：</td>
                <td class="form-cell" colspan="3" valign="top">
                    <textarea name="reason" ng-model="data.reason" cols="30" rows="10" class="textarea"></textarea>
                </td>
            </tr>
            <tr>
                <td class="form-cell w100 pt16" align="right" valign="top">续签明细：</td>
                <td class="form-cell pt16" colspan="3" valign="top">
                    <div class="c-gray">请勾选要续签的应用，未勾选的则对应的是不续签</div>
                    <div class="table-responsive" style="border-top: 1px solid #ddd" ng-clock>
                        <table ng-if="data.projects.length" class="table table-bordered"
                               ng-class="{disable: data.isXq == '0'}" width="100%">
                            <tr ng-repeat="project in data.projects">
                                <td class="w100 ta-c">{{project.projectName}}</td>
                                <td>
                                    <ul class="clearfix select-list">
                                        <li ng-repeat="app in project.apps" ng-class="{active: app.isXq == '1'}">
                                            <a href="javascript:;" ng-click="toggleActive(app, data.isXq)">{{app.appName}}</a>
                                        </li>
                                    </ul>
                                </td>
                            </tr>
                        </table>
                        <div ng-hide="data.projects.length" class="no-data"><span>暂无数据</span></div>
                    </div>
                </td>
            </tr>
            </tbody>
        </table>
    </form>
    <div class="ui-dialog-footer" style="padding: 20px 20px 0 20px;">
        <div class="ui-dialog-button">
            <button type="button" ng-click="prev()" ng-if="step > 1" class="ui-dialog-autofocus">上一步</button>
            <button type="button" ng-click="next()" ng-if="step != maxStep"
                    class="ui-dialog-autofocus">下一步
            </button>
            <button type="button" ng-click="parent.setRemind(data, isProject, items)" ng-if="step == maxStep" class="ui-dialog-autofocus">
                确定
            </button>
            <button type="button" ng-click="close()">取消</button>
        </div>
    </div>
</div>